package com.woniuxy.house.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import java.time.LocalDateTime;
import java.util.List;

/**
 * 用户实体类
 *
 * @author baobo
 * @date 2022-08-26-19:16
 */
@Data
public class User {
	private Integer id;//用户id
	@NotBlank
	@Size(min=3,max = 14)
	private String account;//账号
	private String otherAccount;//别名
	@NotBlank
	@Size(min = 3,max=15)
	private String password;//密码
	private String headPhoto;//头像
	@NotBlank
	@Length(min = 11,max = 11)
	private String telephone;//电话
	private String registTime;//注册时间
	private String userSign;//个性签名
	private String status;//用户状态1正常
	List<Post> posts;
	List<Source> sources;
}
